#ifndef USERMS_H
#define USERMS_H

#include <QWidget>
#include "userinfo.h"

namespace Ui {
class UserMS;
}

class UserMS : public QWidget
{
    Q_OBJECT

public:
    explicit UserMS(QWidget *parent = 0);
    ~UserMS();

    enum Search_Condition{
        Search_None = 0,
        Search_ID,
        Search_Name,
        Search_Tel
    };

    enum Oper_Data{
        Oper_None,
        Oper_Add,
        Oper_Del,
        Oper_Mdf
    };

    void SqlSearchuserinfos(QString sql);

private slots:
    void on_cb_condition_currentIndexChanged(int index);

    void on_pb_search_clicked();

private:
    Ui::UserMS *ui;

    int m_searchCond;
    int m_currentRow;
    UserInfoList m_list;
    void updateTableInfos();
};

#endif // USERMS_H
